
#include "Base.h"

#include "VertexType.h"
#include "Graphics/Vertices/DeclarationElement.h"

namespace CasaEngine
{
	// Size in bytes
	// float : sizeof(float)
	// color : 4 (4 * sizeof(byte))

	const DeclarationElement::TDeclarationElement VertexPositionColor::Elements[] =
	{
		{0, DeclarationElement::Position,  DeclarationElement::Float3},
		{0, DeclarationElement::Diffuse,   DeclarationElement::Color}
	};
	const unsigned int VertexPositionColor::NbElements = 2;

	const DeclarationElement::TDeclarationElement VertexPositionTexture::Elements[] =
	{
		{0, DeclarationElement::Position,  DeclarationElement::Float3},
		{0, DeclarationElement::TexCoord0, DeclarationElement::Float2}
	};
	const unsigned int VertexPositionTexture::NbElements = 2;

	const DeclarationElement::TDeclarationElement VertexPositionColorTexture::Elements[] =
	{
		{0, DeclarationElement::Position,  DeclarationElement::Float3},
		{0, DeclarationElement::TexCoord0, DeclarationElement::Float2},
		{0, DeclarationElement::Diffuse,   DeclarationElement::Color}
	};
	const unsigned int VertexPositionColorTexture::NbElements = 3;

	const DeclarationElement::TDeclarationElement VertexPositionNormalTexture::Elements[] =
	{
		{0, DeclarationElement::Position,  DeclarationElement::Float3},
		{0, DeclarationElement::Normal,    DeclarationElement::Float3},
		{0, DeclarationElement::TexCoord0, DeclarationElement::Float2}
	};
	const unsigned int VertexPositionNormalTexture::NbElements = 3;

	const DeclarationElement::TDeclarationElement VertexPositionColorNormalTexture::Elements[] =
	{
		{0, DeclarationElement::Position,  DeclarationElement::Float3},
		{0, DeclarationElement::Normal,    DeclarationElement::Float3},		
		{0, DeclarationElement::TexCoord0, DeclarationElement::Float2},
		{0, DeclarationElement::Diffuse,   DeclarationElement::Color}
	};	
	const unsigned int VertexPositionColorNormalTexture::NbElements = 4;

} // namespace CasaEnngine

